[add] масло лотофага даёт псиопику#1048
[add] масло лотофага даёт псиопику#1048kekoven1 wants to merge 2 commits intoWWhiteDreamProject:masterfrom
Conversation
WalkthroughДобавлен новый серверный эффект реагента Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~10 minutes Suggested reviewers
🚥 Pre-merge checks | ✅ 2 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (2 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing touches
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Fix all issues with AI agents
In `@Content.Server/_White/Chemistry/Effects/ChemGivePsionics.cs`:
- Around line 13-14: In ChemGivePsionic.cs update the ReagentEffectGuidebookText
override to use the correct localization key
"reagent-effect-guidebook-chem-give-psionic" instead of the current
"reagent-effect-guidebook-chem-remove-psionic"; then add matching entries for
that new key in both Resources/Locale/en-US/guidebook/chemistry/effects.ftl and
Resources/Locale/ru-RU/guidebook/chemistry/effects.ftl with appropriate English
and Russian guidebook text (use the same placeholder ("chance", Probability) as
other entries) so the guidebook string resolves correctly at runtime.
| protected override string? ReagentEffectGuidebookText(IPrototypeManager prototype, IEntitySystemManager entSys) | ||
| => Loc.GetString("reagent-effect-guidebook-chem-remove-psionic", ("chance", Probability)); |
There was a problem hiding this comment.
🧩 Analysis chain
🏁 Script executed:
# First, find and examine the file
find . -name "ChemGivePsionics.cs" -type fRepository: WWhiteDreamProject/wwdpublic
Length of output: 133
🏁 Script executed:
# Search for psionic-related localization keys in ftl files
rg -n "reagent-effect-guidebook-chem.*psionic" --type ftl -iRepository: WWhiteDreamProject/wwdpublic
Length of output: 99
🏁 Script executed:
# Also search for the ChemRemovePsionic file to understand the pattern
find . -name "*RemovePsionic*" -type fRepository: WWhiteDreamProject/wwdpublic
Length of output: 219
🏁 Script executed:
# Read the actual file to verify the code
cat -n ./Content.Server/_White/Chemistry/Effects/ChemGivePsionics.csRepository: WWhiteDreamProject/wwdpublic
Length of output: 1078
🏁 Script executed:
# Read ChemRemovePsionic for comparison
cat -n ./Content.Server/Nyanotrasen/Chemistry/Effects/ChemRemovePsionic.csRepository: WWhiteDreamProject/wwdpublic
Length of output: 1261
🏁 Script executed:
# Search for ftl files without type filter
rg -n "reagent-effect-guidebook.*psionic" --glob="*.ftl"Repository: WWhiteDreamProject/wwdpublic
Length of output: 721
🏁 Script executed:
# Check the full context of the ftl files to see if "give-psionic" key might be under a different name
rg -n "give.*psionic" --glob="*.ftl" -iRepository: WWhiteDreamProject/wwdpublic
Length of output: 54
🏁 Script executed:
# Also check what the remove-psionic key text is to understand the pattern
sed -n '372,377p' ./Resources/Locale/ru-RU/guidebook/chemistry/effects.ftl
sed -n '408,413p' ./Resources/Locale/en-US/guidebook/chemistry/effects.ftlRepository: WWhiteDreamProject/wwdpublic
Length of output: 331
Неправильный ключ локализации в guidebook.
На строке 14 используется ключ "reagent-effect-guidebook-chem-remove-psionic" (удалить), но класс ChemGivePsionic выдаёт псионику, а не удаляет её. Это копирование из ChemRemovePsionic.
Необходимо:
- Заменить ключ на
"reagent-effect-guidebook-chem-give-psionic" - Добавить новый ключ локализации в
Resources/Locale/en-US/guidebook/chemistry/effects.ftlиResources/Locale/ru-RU/guidebook/chemistry/effects.ftl
Предложенное исправление
protected override string? ReagentEffectGuidebookText(IPrototypeManager prototype, IEntitySystemManager entSys)
- => Loc.GetString("reagent-effect-guidebook-chem-remove-psionic", ("chance", Probability));
+ => Loc.GetString("reagent-effect-guidebook-chem-give-psionic", ("chance", Probability));🤖 Prompt for AI Agents
In `@Content.Server/_White/Chemistry/Effects/ChemGivePsionics.cs` around lines 13
- 14, In ChemGivePsionic.cs update the ReagentEffectGuidebookText override to
use the correct localization key "reagent-effect-guidebook-chem-give-psionic"
instead of the current "reagent-effect-guidebook-chem-remove-psionic"; then add
matching entries for that new key in both
Resources/Locale/en-US/guidebook/chemistry/effects.ftl and
Resources/Locale/ru-RU/guidebook/chemistry/effects.ftl with appropriate English
and Russian guidebook text (use the same placeholder ("chance", Probability) as
other entries) so the guidebook string resolves correctly at runtime.
|
🥹 |
|
Как по мне слишком маленькая плата за псионику... |
Описание PR
40 единиц надо
Медиа
Список
Изменения
🆑